package com.wuming.house.service;

import com.wuming.house.core.BusinessException;
import com.wuming.house.model.HouseInfo;
import com.wuming.house.model.HouseLayout;

import java.util.List;

public interface HouseInfoService {

    /**
     * 保存楼盘资讯
     *
     * @param houseInfo 楼盘资讯
     * @throws BusinessException
     */
    void saveHouseInfo(HouseInfo houseInfo) throws BusinessException;

    /**
     * 根据楼盘id查询楼盘资讯
     *
     * @param houseId 楼盘id
     * @return 楼盘资讯
     * @throws BusinessException
     */
    List<HouseInfo> getHouseInfoByHouseId(Long houseId) throws BusinessException;

    /**
     * 修改楼盘动态图信息
     *
     * @param houseInfo 楼盘动态图
     * @throws BusinessException
     */
    void modifyHouseInfo(HouseInfo houseInfo) throws BusinessException;

    /**
     * 删除楼盘动态图信息
     *
     * @param id 动态图id
     * @throws BusinessException
     */
    void removeHouseInfoById(Long id) throws BusinessException;

    /**
     * 根据条件查询动态图信息
     *
     * @param houseId   楼盘id
     * @param infoTitle 动态名称
     * @param pageIndex
     * @param pageSize
     * @return
     */
    List<HouseInfo> getHouseInfoByPage(Long houseId, String infoTitle, int pageIndex, int pageSize) throws BusinessException;

    /**
     * 根据条件查询总数
     *
     * @param houseId
     * @param infoTitle
     * @return
     * @throws BusinessException
     */
    int getTotal(Long houseId, String infoTitle) throws BusinessException;
}
